package com.kedou.sdk.params;

import android.os.Parcel;
import android.os.Parcelable;

/**
 * Created by Administrator on 2017/6/1 0001.
 */

public class LoginRequestParams extends BaseRequestParams implements Parcelable {

    private static final String SERVICE = "login";


    private String username;
    private String password;


    private String pattern = "account";


    public LoginRequestParams() {
    }

    public LoginRequestParams(String user_name, String password) {
        this.username = user_name;
        this.password = password;
    }



    @Override
    public String getServiceString() {
        return SERVICE;
    }



    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPattern() {
        return pattern;
    }

    public void setPattern(String pattern) {
        this.pattern = pattern;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        super.writeToParcel(dest, flags);

        dest.writeString(this.username);
        dest.writeString(this.password);
        dest.writeString(this.pattern);

    }

    protected LoginRequestParams(Parcel in) {
        super(in);
        this.username = in.readString();
        this.password = in.readString();
        this.pattern = in.readString();

    }

    public static final Creator<LoginRequestParams> CREATOR = new Creator<LoginRequestParams>() {
        @Override
        public LoginRequestParams createFromParcel(Parcel source) {
            return new LoginRequestParams(source);
        }

        @Override
        public LoginRequestParams[] newArray(int size) {
            return new LoginRequestParams[size];
        }
    };
}
